#ifndef Tui_TImage_h
#define Tui_TImage_h

#include "TBase.h"

using namespace rapidxml;

class TImage:public TPanelItem{
public:
    TImage();
    
    CREATE_FUNC(TImage);
    
    static TImage*  create(xml_node<> * pItem);
    
    virtual  void  initWidthConf(xml_node<> * pItem);

	void setPath(const char* path);
   
    void setSource(const char* path, int customWidth = 0, int customHeight = 0);
protected:
    CCSprite* m_pItem;
};
#endif
